const router = require('koa-router')();

router.post('/upload', async(context, next) => {

    let keys = Object.keys(context.request.files)
    const filePath = []
    keys.forEach(item => {
        const path = context.request.files[item].path
        filePath.push('http://file.webxiaohua.cn' + path.slice(11, path.length))
    })
    context.body = { src: filePath }
})

module.exports = router;